/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package justdoit.model;

import java.util.Calendar;

/**
 * The entity Class for ONE Task
 * @author Can
 */
public class Task {

    private String id;
    private String description;
    private String category;
    private String deadLine;
    private Priority priority;
    private Integer status;
    private Integer progress;
    private String reminder;
    private Calendar reminderDate;
    private Calendar dueDate;

    public Task() {
        long lid = (System.currentTimeMillis() / 1000);
        id = String.valueOf(lid);
        description = "";
        category = "";
        priority = new Priority(Priority.HIGH);
        status = 0;
        progress = 0;
        deadLine = "";
        reminder = "";
    }

    public void setReminderDate(Calendar reminder) {
        this.reminderDate = reminder;
    }

    public Calendar getReminderDate() {
        return reminderDate;
    }

    public void setDueDate(Calendar dueDate) {
        this.dueDate = dueDate;
    }

    public Calendar getDueDate() {
        return dueDate;
    }

    public String getReminder() {
        return reminder;
    }

    public void setReminder(String reminder) {
        this.reminder = reminder;
    }

    public Integer getProgress() {
        return progress;
    }

    public void setProgress(Integer progress) {
        this.progress = progress;
    }

    public String getCategory() {
        return category;
    }

    public void setCategory(String category) {
        this.category = category;
    }

    public String getDeadLine() {
        return deadLine;
    }

    public void setDeadLine(String deadLine) {
        this.deadLine = deadLine;
    }

    public boolean hasReminder() {
        return (this.reminder != null);
    }

    public String getPriority() {
        return priority.getPriority();
    }

    public void setPriority(String priority) {
        this.priority.setPriority(priority);
    }

    public String getDisplayPriority() {
        return priority.getDisplayPriority();
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getId() {
        return id;
    }

    public void setId(String taskId) {
        this.id = taskId;
    }
}
